Non-volatile memory systems, such as flash memory, have been widely adopted for use in consumer products. Flash memory may be found in different forms, for example in the form of a portable memory card that can be carried between host devices or as a solid state disk (“SSD”) embedded in a host device. Flash memory may be written in pages and erased in blocks, so once a page is written, a rewrite may require the whole block to be erased. When writing data to a conventional flash memory system, a host typically writes data to, and reads data from, addresses within a logical address space of the memory system. In particular, the memory device firmware may handle memory in logical groups and the logical to physical address table (i.e. the global address table or “GAT”) may have an entry for each logical group. The memory system maps data between the logical address space and the physical blocks or meta-blocks of the memory. The GAT identifies data in fixed logical groups corresponding to ranges in the logical address space. Generally, each fixed logical group is stored in a separate physical block of the memory system. The GAT tracks how the logical address space is mapped into the physical memory.
A drawback of memory systems that operate in a logical address space is fragmentation. Data written by a host file system may often be fragmented in logical address space, where many fixed logical groups are only partially updated with new data. In particular, data updates sent by a host may create partially obsolete blocks where valid data occupies part of a block and obsolete data occupies the rest of the block. The fragmentation may occur as a result of cumulative fragmentation of free space by the host file system, and possibly even as a result of inherent fragmentation of individual files by the host file system. Data previously written may become obsolete due to deletion and cause further fragmentation. Free space can generally only be reclaimed in flash memory by performing data copy operations, such as garbage collection, on the partially obsolete blocks. Garbage collection may be needed to aggregate obsolete data together in blocks to be erased. The performance of a memory system may be degraded by increased fragmentation and frequent garbage collection.
A program failure in a block may corrupt the header information, which would limit the logical group information and make garbage collection more difficult or impossible. Identification of which memory (pages/fragments/blocks/meta-blocks) is bad may be necessary for decreasing the risk of losing stored data. For example, memory blocks that are identified as bad may be avoided entirely while good blocks or blocks that are not identified as bad may be used without restrictions. However, avoiding an entire memory block may unnecessarily reduce the overall capacity of the memory. Bad blocks may be replaced with spare blocks, but that also reduces the overall memory capacity, and an insufficient number of spare blocks on a particular die may result in the memory not being able to replace a particular bad block.